POV-Ray : Newsgroups : povray.newusers : conditional statements : Re: conditional statements Server Time
6 Oct 2024 01:59:29 EDT (-0400)
  Re: conditional statements  
From: clipka
Date: 17 Jul 2009 06:15:00
Message: <web.4a604edd6dc58f70a4aed1130@news.povray.org>
"Chris B" <nom### [at] nomailcom> wrote:
> #switch (0)
>   #case(strcmp(DoorModel, "model_101"))
>     ...
>   #break
>   #case(strcmp(DoorModel, "model_102"))
>     ...
>   #break
>   #else
>     ...
> #end

Ah, now *that's* an interesting idea... thanks, even I still live and learn.
I've always missed an #if ... #elseif construct in POV-Ray, but looks like this
is it.

BTW, in POV-Ray 3.7 it should also work with the comparison operator, i.e.:

  #case(DoorModel = "model_101")


Post a reply to this message

Copyright 2003-2023 Persistence of Vision Raytracer Pty. Ltd.